
using System;
using Core.Base;
using Core.Contracts.Enums;
using Core.Contracts.Interfaces;
using Core.Features;
using Core.Resources;
using Core.Extensions;

namespace Core.Items.Robots
{
    /// <summary>
    /// Scarab Mk2 robot class
    /// </summary>
    
    public sealed class ScarabMk2 : RobotBase
    {
        /// <summary>
        /// Create a new instance of the <see cref="T:Core.Items.Robots.ScarabMk2"/> class.
        /// </summary>
        public ScarabMk2()
            : base(
            "Scarab Mk2",
            Traduction.desc_scarab,
            FactionsEnum.Industrial,
            RobotTechnologyLevel.Mk2,
            RobotSizesEnum.HeavyGlider,
            new ISlot[]{ 
				new Slot(0, SlotGroupsEnum.Chassis, SlotTypesEnum.Turret|SlotTypesEnum.Missile|SlotTypesEnum.Misc|SlotTypesEnum.Industrial, SizesEnum.Small|SizesEnum.Medium),
				new Slot(1, SlotGroupsEnum.Chassis, SlotTypesEnum.Turret|SlotTypesEnum.Missile|SlotTypesEnum.Misc|SlotTypesEnum.Industrial, SizesEnum.Small|SizesEnum.Medium),
				new Slot(SlotGroupsEnum.Head, SlotTypesEnum.Modules),
				new Slot(SlotGroupsEnum.Head, SlotTypesEnum.Modules),
				new Slot(SlotGroupsEnum.Head, SlotTypesEnum.Modules),
				new Slot(SlotGroupsEnum.Head, SlotTypesEnum.Modules),
                new Slot(SlotGroupsEnum.Head, SlotTypesEnum.Modules),
				new Slot(SlotGroupsEnum.Legs, SlotTypesEnum.Modules), },
            new IFeature<object>[]{ 
				new AccumulatorCapacity<double>(1250),
				new AccumulatorRechargeTime<double>(720),
				new CpuPerformance<double>(250),
				new ReactorPerformance<double>(250),
				new ArmorAmount<double>(700),
				new ChemicalResistance<double>(30),
				new KineticResistance<double>(45),
				new SeismicResistance<double>(45),
				new ThermalResistance<double>(45),
                new ChemicalEHP<double>(0),
                new KineticEHP<double>(0),
                new SeismicEHP<double>(0),
                new ThermalEHP<double>(0),
				new SurfaceHitSize<double>(12.00),
				new InterferenceEmission<double>(4.00),
				new InterferenceMinimum<double>(75.00),
				new InterferencePeak<double>(340.00),
				new InterferenceRadius<double>(200.00),
				new LockingRange<double>(150),
				new LockingTime<double>(12.50),
				new MaximumTargets<double>(3),
				new MissileGuidanceFailure<double>(0.1),
				new SensorStrength<double>(80),
				new SignalDetection<double>(50.00),
				new SignalMasking<double>(100.00),
				new ReloadingTime<double>(10),
				new CargoCapacity<double>(720.00),
				new RobotMass<double>(63000.00),
				new SlopeCapacity<double>(56),
				new TopSpeed<double>(43.20),
				new Volume<double>(213.00),
                new DemobilizerResistance<double>(0),
                new CriticalHitChance<double>(0)},

            new IBonusModifier[]
            { 
                new BonusModifier<GliderRobotControl>( FeatureTypesEnum.Robot, FeaturesEnum.SurfaceHitSize,-0.3){ Unit = UnitsEnum.Meters, DisplayName = "Surface Hit Size" },
                new BonusModifier<GliderRobotControl>( FeatureTypesEnum.Robot, FeaturesEnum.ShieldAbsorption,0.01){ Unit = UnitsEnum.Meters, DisplayName = "Shield Absorption" },
                new BonusModifier<IndustrialRobotControl>( FeatureTypesEnum.Robot, FeaturesEnum.ArmorAmount,0.01){ Unit = UnitsEnum.Percentage, DisplayName = "Armor Amount" },
                new BonusModifier<AdvancedRobotics>( FeatureTypesEnum.Module, FeaturesEnum.ArmorRepairAmount, 0.05  ){ Unit = UnitsEnum.Percentage, DisplayName = "Armor repair amount" },
                new BonusModifier<AdvancedRobotics>( FeatureTypesEnum.Robot, FeaturesEnum.DemobilizerResistance,0.05){ Unit = UnitsEnum.Percentage, DisplayName = "Demobilizer Resistance" },
                new BonusModifier<AdvancedRobotics>( FeatureTypesEnum.Module, FeaturesEnum.NexusModuleIndustrialModuleCycleTime,-0.01){ Unit = UnitsEnum.Percentage, DisplayName = "Industrial Cycle Time Nexus performance" },
                new BonusModifier<AdvancedRobotics>( FeatureTypesEnum.Module, FeaturesEnum.NexusModuleIndustrialModuleAccumulatorUsage,-0.01){ Unit = UnitsEnum.Percentage, DisplayName = "Industrial Accumulator Usage Nexus performance" },
            
            },
            new ICondition<IExtension>[]
                {
                     new ExtensionCondition<AdvancedRobotics>(4),
                     new ExtensionCondition<IndustrialRobotControl>(10),
                     new ExtensionCondition<GliderRobotControl>(5),

                })
        {
        }
    }
}